package logic

import (
	"context"
	"month/videosvr/internal/service"

	"month/videosvr/internal/svc"
	"month/videosvr/video"

	"github.com/zeromicro/go-zero/core/logx"
)

type MysqlEsLogic struct {
	ctx    context.Context
	svcCtx *svc.ServiceContext
	logx.Logger
}

func NewMysqlEsLogic(ctx context.Context, svcCtx *svc.ServiceContext) *MysqlEsLogic {
	return &MysqlEsLogic{
		ctx:    ctx,
		svcCtx: svcCtx,
		Logger: logx.WithContext(ctx),
	}
}

// MysqlEs todo 数据同步
func (l *MysqlEsLogic) MysqlEs(in *video.MysqlEsReq) (*video.MysqlEsRes, error) {
	// todo: add your logic here and delete this line
	err := service.MysqlEs(in.Index)
	if err != nil {
		return &video.MysqlEsRes{}, err
	}
	return &video.MysqlEsRes{}, nil
}
